
<?

require_once ("application.list.inc");

global $_GLOBAL_DBH;
global $_OBJECT_IFACE_PANEL;

$indexes = array (
	title=>array (label=>"Title",order=>"DEFAULT",wrapper=>"vmc_icon_note"),
	details=>array (label=>"Details",order=>"DEFAULT",callback=>"_template_list_substring",length=>26),
	status=>array (label=>"Status",order=>"DEFAULT",
			values=>array (
				"active",label=>"Active",
				"inactive"=>"Inactive",
				"hold"=>"Hold",
				"suspended"=>"Suspended",
				"processing"=>"Processing",
				"new"=>"New",
				"assigned"=>"Assigned",
				"started"=>"Started",
				"stopped"=>"Stopped",
				"complete"=>"Complete",
			)),
	cdate=>array (label=>"Begin Date",order=>"DEFAULT",wrapper=>"vmc_icon_date"),
);

$object_ctl = "/admin/users/tasks/fs_tasks.php?fs_tab=notes&task_id={$_REQUEST["task_id"]}&fs_tab_option=fs_notes&fs_action=view&";
$link_options = "&fs_action=view&fs_tab=notes&task_id={$_REQUEST["task_id"]}";
$list_options = array (
	array (
		label=>"Add Task Note",
		link=>"fs_tasks.php?fs_tab=notes&task_id={$_REQUEST["task_id"]}&fs_tab_option=fs_notes&fs_action=addnew"
	),
);

$_OBJECT_IFACE_LIST = _app_create_list_object (array (
                db_conn=>$_GLOBAL_DBH,
                indexes=>$indexes,
		list_count=>"SELECT COUNT(*) FROM task_notes WHERE task_id={$_REQUEST["task_id"]}",
		list_select=>"SELECT * FROM task_notes WHERE task_id={$_REQUEST["task_id"]}",
                list_id=>"lc_utask_notes",
                list_options=>$list_options,
                primary_key=>"id",
                primary_relation=>"note_id",
                link_options=>$link_options,
                object_ctl=>$object_ctl
));


$_OBJECT_IFACE_TABBING_PANEL->insert_container ($_OBJECT_IFACE_LIST);

?>
